#! usr/bin/python3
# coding=utf-8
# @Time: 2025/9/20 
# @Author: GaoSheng
from base.constance import ApiService
from base.helper import api
from client_core.HttpClient import HttpClient


class ClientCommon(HttpClient):

    def set_header(client, method, request):
        request['headers'] = {"Content-Type": "application/x-www-form-urlencoded"}

    def __init__(self, base_url, session=None, **kwargs):
        super().__init__(base_url, session, **kwargs)
        self.token = None

    @api("/tenant/v2/token", method="post")
    def get_access_token(self, appid=ApiService.appid, secret=ApiService.secret):
        pass
